<!--
 * @Author: luthor luthor-li@qq.com
 * @Date: 2024-03-09 01:01:08
 * @LastEditors: fisher luthor-li@qq.com
 * @LastEditTime: 2024-03-09 23:37:04
 * @FilePath: \allfront\src\modules\cloud\projManager\bigfileDialog.vue
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
-->
<template>
  <el-dialog
    v-model="dialogFormVisible"
    title="大文件列表"
    width="1000"
    :destroy-on-close="true"
  >
    <el-table ref="multipleTableRef" :data="bigfileData" style="width: 100%">
      <el-table-column property="name" label="文件名" width="120" />
      <el-table-column property="size" label="文件大小" width="120" />
      <el-table-column
        property="createdAt"
        label="上传时间"
        show-overflow-tooltip
      />
      <el-table-column label="操作">
        <template #default="scope">
          <el-button type="primary" @click="publish(scope.row)">
            发布
          </el-button>
        </template>
      </el-table-column>
    </el-table>
  </el-dialog>
</template>

<script setup>
import { ref, defineExpose } from 'vue';
// 弹窗状态
const dialogFormVisible = ref(false);
defineProps({
  bigfileData: {
    type: Array,
    default() {
      return [];
    },
  },
});
const emit = defineEmits(['handlePublish']);
const publish = data => {
  emit('handlePublish', data);
};
defineExpose({ dialogFormVisible });
</script>
